The invention relates to fax machines, printers, multifunction machines and other machines having print engines. More specifically, the invention relates to print controllers and code development for such machines.
During manufacture of fax machines, printers, multifunction machines and other machines including print engines, an original equipment manufacturer (xe2x80x9cOEMxe2x80x9d) purchases a xe2x80x9ccore.xe2x80x9d The core typically includes print head drives, paper motor drives, carriage motor drives, paper sensors and flags, and controllers programmed with basic functions and variable values to control these core printing devices. The OEM then adds certain features to the core to produce a finished product. For example, different OEMs might add different cases and different paper path mechanisms to their fax machines.
The OEM may purchase some or all of these core components from a vendor. At a minimum, however, the OEM typically purchases, a print controller and print read-only memory (xe2x80x9cROMxe2x80x9d) from the vendor because these components control the very basic, or low level, functions of the core printing devices. The remaining core components may be purchased from sources other than the print controller vendor.
The print ROM stores control code for controlling the print engine. The control code includes xe2x80x9cgenericxe2x80x9d executable code and device-specific executable code.
During code development, the vendor generates the control code. If the OEM purchases core printing devices from a source other than the vendor, the device-specific code generated by the vendor might be different from the specific paper path of the OEM design.
The current practice is for the vendor to supply portions of source code to the OEM, and let the OEM modify the source code and determine final functions and variable values that work with the OEM""s machine. If the default paper path is different than the paper path used by the OEM, the OEM modifies the vendor-supplied variable values and paper path functions. Once the device-specific code has been developed by the OEM, the OEM sends the modified device-specific source code (including the modified variable values and paper path functions) to the vendor. The vendor then compiles the entire source code, burns the compiled code into the print ROM, and delivers the print ROM back to the OEM. The print ROM is mounted in the OEM""s machine.
Three problems are inherent in such code development. First, the vendor provides generic source code to the OEM, and the OEM provides device-specific source code to the vendor. Thus, each party exposes valuable intellectual property to the other. However, this approach is not desirable for a party who desires to protect its source code.
Second, the code development is performed sequentially, which takes time. Developing the vendor and OEM code in parallel would be faster and more efficient.
Third, the vendor customizes its print ROM for each OEM. Providing different print ROMs to different OEMs can be costly to the vendor.
These problems are overcome by the present invention. According to one aspect of the present invention, an apparatus includes a print engine having a first controller and scratch memory. A portion of the scratch memory is reserved for a jump table. The apparatus further includes a second controller. During startup of the apparatus, the second controller passes variable values and functions to the print controller. The print controller writes the variable values to specific locations in the jump table. The print controller also writes the functions to the scratch memory and writes starting addresses of these functions to specific locations in the jump table. The print controller uses the jump table to access the variable values and execute the functions. Thus, the jump table allows the second controller to share variables and functions with the first controller. Such an architecture allows code to be developed more efficiently. It also allows code to be protected, and the manufacturing cost of the print controller to be reduced.